import {Entity, Column} from 'typeorm';
import {BaseEntity} from "@/entitys/common/baseEntity";

// 账单类型
export enum BillTypeEnum {
    "Receivable" = "0", //应收款
    "Payable" = "1", // 应付款
}

@Entity({comment: "账单流水"})
export class BillFlow extends BaseEntity {

    @Column({comment: '应收应付款账单ID'})
    tripDataId: number;

    @Column({comment: "账单类型", type: "enum", enum: BillTypeEnum, default: BillTypeEnum.Receivable})
    billType: BillTypeEnum;

    @Column({comment: '收付款金额'})
    amount: number;

}
